Distributing software in a global marketplace requires a user interface that is accessible to a variety of users. Generally, an interface is the point at which a connection is made between two elements so that they can work with each other or exchange information. For computer software purposes, an interface is typically software that enables a program to work with the user, with another program including an operating system, or with the computer's hardware. An interface that enables a program to work with a user is called a user interface, which can be a command-line interface, a graphical user interface, or a menu-driven interface.
To facilitate the use of a common user interface (“UI”) in different countries/regions, the UI should support multiple languages. A software program usually comprises functional code and localizable UI elements or resources. To provide multiple-language UIs for a software program, traditionally, a software provider localizes the entire software program, and then generates binaries (with code and resources) for each of the supported languages. The traditional approach is generally inefficient, however, in that the software provider must maintain separate software code bases for each of the supported languages. Accordingly, the software provider must independently support each separate software code base, such as providing technical support, providing updates, and/or providing patches.
Another approach to expand the languages supported by a UI utilizes a common software code base in conjunction with various language-specific resource libraries. One such system is Microsoft Corporation's multilingual user interface (“MUI”). Generally described, a MUI-based operating system (“MUI system”) includes a common code module and a default resource module that serves as a default language for the UI. Additionally, the MUI system maintains a number of alternative language-specific resource modules for displaying some or all the UI objects in an alternative language. Accordingly, if a user or an application specifies one of the alternative languages supported by the MUI system, the MUI system loads the resources from the corresponding alternative language resource module. For example, if a user selects Spanish as a desired UI language, the operating system (“OS”) loads the system resources from a Spanish-specific resource module.
Generally described, a UI resource is an item of data, such as a dialog box or a font in a Windows® environment, that can be displayed on a computer screen. Many UI features in a software program can be altered by adding or replacing UI resources without modifying the program's source code. Resource data usually consists of the data structures, templates, definition procedures, management routines, icon maps, and so forth associated with a particular UI resource, such as a menu, window, or dialog box. An OS often maintains a number of UI resource modules, each of which consisting of UI resources that are used by the OS to realize a specific UI feature.
MUI systems may include various resource loaders. A resource loader obtains and loads resources from the desired language-specific resource module. A resource loader selects between loading resources from a default resource module, typically encoded in English, or from a designated language-specific alternate resource module. Typically, if a desired alternate resource module is unavailable, a resource loader selects the default resource module.
In a MUI system, in order to load the right language file from a list of available ones, each resource loader needs to know what to look for based on a set of rules. These rules are called resource probing rules, which regulate the decision-making process for loading a particular resource. The resource probing rules thus dictate what is displayed to a user of an application or OS. Different limitations, such as imposed by the OS, a software application, and/or a user of the OS or the software application, define resource probing rules for a resource loader.
FIG. 1 illustrates exemplary categories of factors that dictate what system UI is displayed to an end user in a MUI system. The first category is System UI Localization Coverage and Dependency 102. In a MUI system, the OS and/or its components can be partially localized to a particular language and a dependent language is used to substitute the non-localized portion. A resource loader thus needs to know this dependency and tries the dependent language's resources when the resource loader can not locate the resources for the partially localized language.
The second category is System UI Package Offering 104. Depending on what is offered and installed on a particular system, the resource presence for a particular language and for a particular component can be very different. In particular, when a dependent language is used to substitute a partially localized language, the UI languages offered and installed by a system UI package can affect the dependent language available for the partially localized language.
The third category is User UI Language Preference 106. A user of a MUI system can select a particular language as the user's preferred UI language. Often, a user may understand a set of languages instead of just one, and would prefer the system to direct the UI display based on the user's known language list and/or preference. Such a preference may be particularly important to a user if a software program is only partially localized in the user's primary language. For example, a Hong Kong user may prefer to read English instead of simplified Chinese when a software program does not have the user's preferred traditional Chinese UI.
The fourth category is Application Localization Dependency or User Preference 108. Similar to the first category—the System Localization Coverage and Dependency 102, an application's resource coverage can be different among languages. For example, the application can be partially localized in some languages to save localization cost. An application may have different UI language coverage from the system in which the application runs. A user can select to use a particular UI language for the application.
The fifth category of factors that dictate what is displayed to a user is Cultural and Language Relationships 110. A natural relationship usually exists among languages, particularly among languages that share the same root. These languages may be different only in accents or are minor progressive adoptions of the exact same language, i.e., the root language. The root language is sometimes referred to as the neutral language, and the others are referred to as a language specific. For example, English is the neutral, original language, while American English, British English, and Australian English are the exemplary languages specifics for the root language English. From a UI localization perspective, if resources for a particular language specific are not found, a natural substitute will be the corresponding resources of the neutral language, i.e., the root language of the language specific.
The sixth category of factors that dictate what is displayed to a user in a MUI system is Design Time Knowledge 112. When everything fails, a resource loader may load the original UI language that a program designer uses during software creation time. The resource loader trusts that the program designer provides the original UI language accurately. When a resource for a particular language does not exist, for example, either because the resource is not installed or localized to the particular language, the resource loader can always try the original UI language designated by the program designer at the software creation time.
Therefore, each category of factors dictates the use of a specific list of languages. For example, an application's UI language availability and user selection dictates a UI language preference list for the application. A user's UI language preference decides the languages in which a resource loader can select to load the resources in. Thus, any factor in these exemplary categories can affect the availability of a particular resource or the appropriateness of using a particular resource. The variety and complexity of factors thus affect the set of resource probing rules, i.e., the process that a resource loader decides what resources to load. If every single resource loader in a MUI system implements its own resource probing rule, different resource probing rules may be used in a MUI system and cause random and mixed language UI items being displayed to a user.
Therefore, there exists a need to centralize resource probing rules applicable to a MUI system and enable the system, applications in the system, and users of the application and system to communicate with centralized resource probing rules via a standard interface.